<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        /* css reset--为了统一浏览器的显示效果，清除自带样式 */
        /*
YUI 3.18.1 (build f7e7bcb)
Copyright 2014 Yahoo! Inc. All rights reserved.
Licensed under the BSD License.
http://yuilibrary.com/license/
*/
        html {
            color: #000;
            background: #FFF
        }

        body,
        div,
        dl,
        dt,
        dd,
        ul,
        ol,
        li,
        h1,
        h2,
        h3,
        h4,
        h5,
        h6,
        pre,
        code,
        form,
        fieldset,
        legend,
        input,
        textarea,
        p,
        blockquote,
        th,
        td {
            margin: 0;
            padding: 0
        }

        table {
            border-collapse: collapse;
            border-spacing: 0
        }

        fieldset,
        img {
            border: 0
        }

        address,
        caption,
        cite,
        code,
        dfn,
        em,
        strong,
        th,
        var {
            font-style: normal;
            font-weight: normal
        }

        ol,
        ul {
            list-style: none
        }

        caption,
        th {
            text-align: left
        }

        h1,
        h2,
        h3,
        h4,
        h5,
        h6 {
            font-size: 100%;
            font-weight: normal
        }

        q:before,
        q:after {
            content: ''
        }

        abbr,
        acronym {
            border: 0;
            font-variant: normal
        }

        sup {
            vertical-align: text-top
        }

        sub {
            vertical-align: text-bottom
        }

        input,
        textarea,
        select {
            font-family: inherit;
            font-size: inherit;
            font-weight: inherit;
            *font-size: 100%
        }

        legend {
            color: #000
        }

        #yui3-css-stamp.cssreset {
            display: none
        }
        .warp {
            display: flex;
            /* 主轴方向竖直 */
            flex-direction: column;
            height: 100vh;
        }

        .header {
            height: 100px;
            background-color: #e22;
        }

        .center {
            background-color: orange;
            flex: 1;
            display: flex;
        }

        .aside1 {
            width: 150px;
            background-color: yellow;
        }

        .content {
            flex: 1;
        }

        .aside2 {
            width: 150px;
            background-color: blue;
        }

        .footer {
            height: 100px;
            background-color: greenyellow;
        }
    </style>
</head>

<body>
    <!-- 准备一个外层的容器，包住header、center、footer 再用弹性布局 上下固定 中间可变 主轴竖直 -->
    <div class="warp">
        <div class="header">Header</div>
        <div class="center">
            <div class="aside1"></div>
            <div class="content"></div>
            <div class="aside2"></div>
        </div>
        <div class="footer">Footer</div>
    </div>
</body>

</html>